-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix 123 unittests by autofix #358
Fix 123 unittests by autofix #358
Conversation
Thanks for your contribution! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
有些没实现的,也需要min_input_args吗,因为也没单测
@@ -1978,7 +1986,9 @@ | |||
"memory_format" | |||
] | |||
}, | |||
"torch.Tensor.lstsq": {}, | |||
"torch.Tensor.lstsq": { | |||
"min_input_args": 1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这种没有实现的API,也需要加 min_input_args
字段吗
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个里面的 min_input_arg 是基于 python 函数签名计算的,因为感觉后续用得到所以先加上了,要先移除吗
paconvert/api_mapping.json
Outdated
@@ -3321,8 +3343,7 @@ | |||
"min_input_args": 0, | |||
"args_list": [ | |||
"dtype", | |||
"non_blocking", | |||
"dst_type" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个要留着,因为是为了适配torch.nn.Module.type
,TensorTypeMatcher里包含torch.nn.Module.type
的功能。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
原来如此,好的
tests/test_nn_Module_type.py
Outdated
def test_case_2(): | ||
# paddle not support: 'Layer' object has no attribute 'type' | ||
# convert failed when using keyword argument. | ||
def _test_case_2(): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个把历史功能弄没了,是在TensorTypeMatcher里实现的
paconvert/api_mapping.json
Outdated
} | ||
}, | ||
"unsupport_args": [ | ||
"_stacklevel" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个不是直接删除了,对应"",还需要unsupport吗
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
已解决
"torch.linalg.solve_triangular": 'keyword arg "upper" has no default value', | ||
"torch.sparse_csr_tensor": "paddle must specified arg `shapes`", | ||
"torch.nn.GRUCell": "paddle result has diff with pytorch result when all parameters use default value", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这些问题case你这边整理下,维护一个像这样的excel吧,不然这些问题永远得不到修复
PaddlePaddle/Paddle#55883
整理好excel列表后给我,我后面推动框架进行升级修复
PR Docs
(半)自动修复了 123 个 api 单测。
非特殊情况的常见单测覆盖问题存量已清空。
PR APIs